/* 🌊 生物城水世界研学基地 - 自定义样式 */

/* ==============================================
   🎨 全局样式
   ============================================== */

:root {
    /* 主题色彩 */
    --primary-color: #0066cc;
    --secondary-color: #00a8ff;
    --accent-color: #ffd700;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
    
    /* 水主题色彩 */
    --water-light: #e3f2fd;
    --water-medium: #90caf9;
    --water-dark: #1976d2;
    --water-deep: #0d47a1;
    
    /* 字体配置 */
    --font-family-base: 'Microsoft YaHei', '微软雅黑', 'PingFang SC', sans-serif;
    --font-size-base: 16px;
    --line-height-base: 1.6;
    
    /* 动画配置 */
    --transition-base: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --animation-duration: 0.5s;
}

/* 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family-base);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    color: #333;
    background: linear-gradient(135deg, #e3f2fd 0%, #f8f9fa 100%);
    overflow-x: hidden;
}

/* ==============================================
   🎯 导航栏样式
   ============================================== */

.navbar {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 102, 204, 0.1);
    transition: var(--transition-base);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color) !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-brand i {
    animation: waterDrop 2s ease-in-out infinite;
}

.navbar-nav .nav-link {
    font-weight: 500;
    color: #555 !important;
    padding: 0.5rem 1rem !important;
    border-radius: 25px;
    transition: var(--transition-base);
    position: relative;
}

.navbar-nav .nav-link:hover {
    color: var(--primary-color) !important;
    background: rgba(0, 102, 204, 0.1);
    transform: translateY(-2px);
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: var(--transition-base);
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after {
    width: 70%;
}

/* ==============================================
   🌟 英雄区域样式
   ============================================== */

.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><defs><radialGradient id="a" cx="50%" cy="40%"><stop offset="0%" stop-color="%23e3f2fd" stop-opacity=".3"/><stop offset="100%" stop-color="%23f8f9fa" stop-opacity="0"/></radialGradient></defs><rect width="100" height="20" fill="url(%23a)"/></svg>') no-repeat center;
    background-size: cover;
    z-index: -1;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
}

.hero-content .lead {
    font-size: 1.25rem;
    color: #666;
    margin-bottom: 2rem;
}

.hero-stats {
    background: rgba(255, 255, 255, 0.8);
    padding: 1.5rem;
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 102, 204, 0.1);
}

/* 水滴动画 */
.water-animation {
    position: relative;
    display: inline-block;
}

.water-animation i {
    font-size: 8rem;
    color: var(--primary-color);
    animation: float 3s ease-in-out infinite;
}

.ripple {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100px;
    height: 100px;
    border: 2px solid var(--water-medium);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: ripple 2s linear infinite;
}

.ripple-2 {
    animation-delay: 1s;
}

/* ==============================================
   🎨 功能卡片样式
   ============================================== */

.feature-card {
    transition: var(--transition-base);
    border: none;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.7s;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0, 102, 204, 0.15) !important;
}

.feature-icon {
    transition: var(--transition-base);
}

.feature-card:hover .feature-icon {
    transform: scale(1.1);
}

/* ==============================================
   🚀 快速导航卡片
   ============================================== */

.quick-nav-card {
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.quick-nav-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.quick-nav-card:hover::before {
    transform: translateX(100%);
}

.quick-nav-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
}

.quick-nav-card.bg-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
}

.quick-nav-card.bg-success {
    background: linear-gradient(135deg, var(--success-color), #20c997) !important;
}

.quick-nav-card.bg-warning {
    background: linear-gradient(135deg, var(--warning-color), #fd7e14) !important;
}

.quick-nav-card.bg-info {
    background: linear-gradient(135deg, var(--info-color), #667eea) !important;
}

/* ==============================================
   📝 按钮样式优化
   ============================================== */

.btn {
    border-radius: 25px;
    font-weight: 600;
    padding: 0.75rem 2rem;
    transition: var(--transition-base);
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.4);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

/* ==============================================
   🌈 动画效果
   ============================================== */

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes ripple {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }
    100% {
        width: 200px;
        height: 200px;
        opacity: 0;
    }
}

@keyframes waterDrop {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* ==============================================
   📱 响应式设计
   ============================================== */

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-content .lead {
        font-size: 1.1rem;
    }
    
    .water-animation i {
        font-size: 6rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn {
        padding: 0.6rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .feature-card,
    .quick-nav-card {
        margin-bottom: 1rem;
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .display-4 {
        font-size: 2.5rem;
    }
    
    .display-5 {
        font-size: 2rem;
    }
    
    .water-animation i {
        font-size: 4rem;
    }
    
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* ==============================================
   🎨 自定义滚动条
   ============================================== */

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* ==============================================
   🌟 特殊效果
   ============================================== */

.glass-effect {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;
}

.text-gradient {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-custom {
    box-shadow: 0 10px 30px rgba(0, 102, 204, 0.15);
}

.shadow-hover {
    transition: var(--transition-base);
}

.shadow-hover:hover {
    box-shadow: 0 15px 40px rgba(0, 102, 204, 0.2);
}

/* ==============================================
   🎯 辅助类
   ============================================== */

.text-primary-gradient {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-water-light {
    background: linear-gradient(135deg, var(--water-light), #f8f9fa);
}

.bg-water-medium {
    background: linear-gradient(135deg, var(--water-medium), var(--water-light));
}

.border-water {
    border-color: var(--water-medium) !important;
}

.hover-lift {
    transition: var(--transition-base);
}

.hover-lift:hover {
    transform: translateY(-5px);
}

/* ==============================================
   📚 页面特定样式
   ============================================== */

/* 研学导览页面 */
.interactive-map {
    position: relative;
    background: linear-gradient(135deg, var(--water-light), #ffffff);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: var(--shadow-custom);
}

.map-point {
    position: absolute;
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    cursor: pointer;
    transition: var(--transition-base);
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.3);
}

.map-point:hover {
    transform: scale(1.2);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.4);
}

.map-point.active {
    background: var(--danger-color);
    animation: pulse 1s infinite;
}

/* 知识库页面 */
.knowledge-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-custom);
    transition: var(--transition-base);
    border-left: 5px solid var(--primary-color);
}

.knowledge-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.process-step {
    background: linear-gradient(135deg, var(--water-light), white);
    border-radius: 15px;
    padding: 1.5rem;
    margin: 1rem 0;
    position: relative;
    transition: var(--transition-base);
}

.process-step:hover {
    transform: translateX(10px);
    box-shadow: var(--shadow-hover);
}

/* 实验页面 */
.experiment-card {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-custom);
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
}

.experiment-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(45deg, var(--warning-color), var(--success-color));
}

.experiment-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.safety-notice {
    background: linear-gradient(135deg, #fff3cd, #ffeaa7);
    border: 1px solid #ffc107;
    border-radius: 10px;
    padding: 1rem;
    margin: 1rem 0;
}

.material-list {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    margin: 1rem 0;
}

.material-list ul {
    list-style: none;
    padding: 0;
}

.material-list li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    align-items: center;
}

.material-list li:last-child {
    border-bottom: none;
}

.material-list li::before {
    content: '🧪';
    margin-right: 0.5rem;
    font-size: 1.2rem;
}

/* 动画效果 */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

.bounce {
    animation: bounce 1s infinite;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 102, 204, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 响应式字体大小 */
@media (max-width: 768px) {
    .knowledge-card,
    .experiment-card {
        padding: 1.5rem;
    }
    
    .process-step {
        padding: 1rem;
    }
    
    .interactive-map {
        padding: 1rem;
    }
}

/* 打印样式 */
@media print {
    .navbar,
    footer,
    .btn,
    .interactive-map {
        display: none !important;
    }
    
    .knowledge-card,
    .experiment-card {
        box-shadow: none;
        border: 1px solid #ddd;
        break-inside: avoid;
    }
}